Complex event processing (CEP), in which data generated in a system is monitored in real-time as a stream and a certain process is executed depending on the pattern of the data thus monitored, has been increasingly becoming popular in recent years. While CEP is sometimes referred to as event stream processing (ESP), ESP is herein included in CEP and collectively referred to as CEP.
As an example of CEP, a fluctuation of a stock price or a currency exchange rate is received as a stream, and transactions are executed corresponding to the pattern of the fluctuation. As another example, a temperature detected with a temperature sensor installed outdoor or indoor is received as a stream, and a sprinkler is caused to operate automatically corresponding to a temperature change.
In CEP, a received stream is matched against a condition expression, which is referred to as a query or a rule, to detect an event, and the event thus detected is executed. As an example, a server performing CEP stores therein a rule X for executing an event X when a phenomenon A, a phenomenon B, and a phenomenon C are detected consecutively, and a rule Y for executing an event Y when the phenomenon A, the phenomenon B, and a phenomenon D are received within a predetermined time period.
The server detects a phenomenon from a received stream and stores the phenomenon in a memory or the like as intermediate data. When the phenomenon A, the phenomenon B, and the phenomenon C are stored consecutively as intermediate data, the server executes the event X. When the phenomenon A, the phenomenon B, and the phenomenon D are stored as intermediate data within the predetermined time period, the server executes the event Y. A related-art example is described in IT Architect, Vol. 23, IDG Japan, 2009, pp. 128-132.
Conventional technologies sometimes cause deterioration of processing performance.
For example, in CEP to which a plurality of rules are applied, a plurality of servers or a plurality of virtual machines (VMs) are used to reduce the processing load and to detect events from streams in real-time. Memories or virtual memories are not shared between the servers or the VMs, and therefore, the intermediate data and the like may not be managed in a shared manner. Therefore, in conventional technologies, interrelated rules are assigned to the same serve or the same VM before starting CEP.
After starting the CEP, if an event detected by a certain rule occurs frequently, or if the stream load increases, the server assigned with such a rule needs to execute the event frequently, and the processing load of the server increases. As a result, the process of detecting an event from a stream is delayed in the server in which the event occurs frequently, and the server becomes incapable of processing the event in real-time. In other words, when a particular event is detected frequently, the processing performance of the entire CEP deteriorates.